home *** CD-ROM | disk | FTP | other *** search
- On 06-Mar-98, Magnus.Sjoberg@asdo.se smashed the keyboard with:
- >> 's a little trick I found the other day, hope somebody can
- > use it..
- >
- >> store an integer-array you would normaly open a sequentiel
- > file and dump
- >> data with a loop.. Well try this instead:
- >> =50
- >> A(MX)
- >> -
- >> FILE$,Varptr(A(0)) To Varptr(A(0))+(MX+1)*4
- >>
- >> to reload:
- >> FILE$,Varptr(A(0))
- >>
- >> can simply replace Bsave with Ssave if you'd like to have
- > more than one
- >> in a file. Or use Copy to put in a bank :)
- >
- > Thanx for the tip. It's just what I need.
- > Loop-storing/reading are so slow when it comes to bigger files.
- > But how about big numbers and strings? I sence a bit of trouble
- > here...
-
- Strings don't work :(
- All regular integer-arrays work (A(n), B(n)) etc.. With a little change it
- is possible to use multi-dimension arrays. The (MX+1) should just be changed
- to the number of elements in the array, so if you have a Dim A(6,6) then the
- (MX+1) is changed to (7*7) element 0 is the first, resulting in 7 in each
- dimension..
-
- Integer holds numbers from -$80000000 -> $7FFFFFFF wich equals to
- -2.147.483.648 -> 2.147.483.647, if you'd like to use floating numbers like
- A#(n) then the *4 is changed to the length of each element in the floating
- set (Still *4 if you're using Single/Fast float, but *8 if you are using
- Double Precision numbers..)..
-
- --
- Kind regards from
- ______________________________________________________________________________
- /_ __/ __ / __ /\ ___\ __ \__ _\ aka. JENS VANG PETERSEN
- / / / /_/ / ____/ \ \___\ __ \ \ \ top_cat@post8.tele.dk
- /_/ /_____/_/ \_____\_\ \_\ \_\
- ------------------------------------------------------------------------------
- http://home8.inet.tele.dk/top_cat/
- -+- Home of 'The Ultimate Extension list' for AMOS TC & AMOS PRO -+-
- -+- SUPPORT - AMOS - AMIGA - AQUA -+-
- ------------------------------------------------------------------------------
- Hardware: The parts of a computer system that can be kicked.
- ------------------------------------------------------------------------------
-
-
-